---
title: SAIF.Business.View.Policy operations and processes
summary: Business and technical operations supported by this library.
status: draft
owner: SAIF Claims BOF team
last_reviewed: 2026-08-21
library: SAIF.Business.View.Policy
reference_type: embedded
---

# SAIF.Business.View.Policy operations and processes

This page is the operation catalog and cross-operation hub for this library. Each operation's detailed, step-by-step logic lives in its own page under `operations/`.

## Operation catalog

| Operation | Intent | Trigger | Inputs | Outputs | Rules | Tables | SQL |
| --- | --- | --- | --- | --- | --- | --- | --- |
| [Retrieve policy header data](operations/retrieve-policy-header-data.md) | Load the aggregate "policy header" view object for a given policy | Caller invokes `clsPolicyData.GetPolicyData(...)` | Policy number (or batch), optional `UserAccessLevel` | Populated `clsPolicyData` object | [BR-VP-001](business-rules.md#br-vp-001-valid-policy-number-required) | *(not directly visible)* | [SQL-VP-008](sql/SQL-008-getpolicy.md) |
| [Determine whether the current user may view a policy](operations/determine-policy-access.md) | Authorize (or deny) the current user's access to a specific policy | Caller invokes `clsPolicySecurity.IsPolicyValidForUser(...)` | `clsPolicyData` (or policy number), current `clsSecurityPrincipal`/`clsUserType` | `Boolean hasAccess` | [BR-VP-002](business-rules.md#br-vp-002-secure-policy-ad-resource-gate), [BR-VP-003](business-rules.md#br-vp-003-policy-validity-and-non-zero-policy-number-required-for-access), [BR-VP-004](business-rules.md#br-vp-004-unconditional-access-for-internal-staff-user-types), [BR-VP-005](business-rules.md#br-vp-005-agent-ownership-match-required), [BR-VP-006](business-rules.md#br-vp-006-policyholder-ownership-affiliation-match-required), [BR-VP-007](business-rules.md#br-vp-007-group-membership-required), [BR-VP-008](business-rules.md#br-vp-008-loss-control-consultant-assignment-match-required), [BR-VP-009](business-rules.md#br-vp-009-fee-auditor-vendor-policy-audit-record-match-required) | [PA_AUDIT](database-tables.md#pa_audit) | [SQL-VP-033](sql/SQL-033-isingroup.md), [SQL-VP-037](sql/SQL-037-canauditoraccesspolicy.md) |
| [Build the current user's book of business](operations/build-book-of-business.md) | Produce the list of policies the current user is entitled to see | First access to `clsPolicySecurity.PolicyList` property | Current `clsUserType`, associated agent/group/loss-control/auditor identifiers | `List(Of strPolicyList)` | *(none directly — list construction, not a gate)* | *(not directly visible)* | [SQL-VP-034](sql/SQL-034-getpolicylistforgroup.md), [SQL-VP-035](sql/SQL-035-getpolicylistforsafetyconsultant.md), [SQL-VP-036](sql/SQL-036-getpolicylistforagent.md), [SQL-VP-038](sql/SQL-038-getauditorpolicylistsql.md) |
| [Retrieve payroll classification detail](operations/retrieve-payroll-classification-detail.md) | Load manual-classification/payroll detail lines for a policy period, selecting the correct era-specific query | Caller supplies `ClassCoverageSetID` (PMS-era) or `PremiumSetID` + date range (WCIS-era) via `Criteria` | `ClassCoverageSetID` or `PremiumSetID`/date range | Collection of `clsPayrollClassInfo` | *(none directly)* | [PPNW_CLASS_COVERAGE_DETAIL](database-tables.md#ppnw_class_coverage_detail), [PREM_HIST_CLASS_COVERAGE](database-tables.md#prem_hist_class_coverage) | [SQL-VP-030](sql/SQL-030-retrieve_pms_sql.md), [SQL-VP-031](sql/SQL-031-retrieve_wcis_sql.md) |

## Process flow diagram

The following diagram visualizes the primary operational flow across operations.

```mermaid
flowchart TD
	Start([Caller requests policy detail]) --> Retrieve[Retrieve policy header data]
	Retrieve --> Access{Determine whether the current user may view a policy}
	Access -->|Granted| BookOfBusiness[Build the current user's book of business]
	Access -->|Denied| Deny([Access denied — no data returned])
	BookOfBusiness --> Payroll[Retrieve payroll classification detail]
	Payroll --> EndOk([Policy detail rendered to caller])
```

## Inherited operations and processes

Retrieval and validation infrastructure (`RetrieveObject`, `Rules.CheckRules`, `Fill`/`MarkOld`
lifecycle) for every business object/collection in this library is provided by `clsBusinessBase`,
`clsBusinessCollection(Of T)`, and `clsBusinessCollectionBase` in `saif.framework.core`. No
concrete, domain-specific inherited operation descriptions were returned from the dependency
documentation lookup for these base classes — only generic BOF Framework lifecycle mechanisms — so
no per-operation "Inherited operations" block is included here. See
[dependencies.md](dependencies.md) for the full base-class list.

## Database interactions

| Operation | SQL | Tables | Type |
| --- | --- | --- | --- |
| [Retrieve policy header data](operations/retrieve-policy-header-data.md) | [SQL-VP-008](sql/SQL-008-getpolicy.md) | *(not directly visible)* | Read |
| [Determine whether the current user may view a policy](operations/determine-policy-access.md) | [SQL-VP-033](sql/SQL-033-isingroup.md), [SQL-VP-037](sql/SQL-037-canauditoraccesspolicy.md) | [PA_AUDIT](database-tables.md#pa_audit), [PA_AUDITOR](database-tables.md#pa_auditor), [PA_POLICY_PERIOD](database-tables.md#pa_policy_period) | Read |
| [Build the current user's book of business](operations/build-book-of-business.md) | [SQL-VP-034](sql/SQL-034-getpolicylistforgroup.md), [SQL-VP-035](sql/SQL-035-getpolicylistforsafetyconsultant.md), [SQL-VP-036](sql/SQL-036-getpolicylistforagent.md), [SQL-VP-038](sql/SQL-038-getauditorpolicylistsql.md) | [POLICY](database-tables.md#policy), [PA_AUDIT](database-tables.md#pa_audit), [PA_AUDITOR](database-tables.md#pa_auditor) | Read |
| [Retrieve payroll classification detail](operations/retrieve-payroll-classification-detail.md) | [SQL-VP-030](sql/SQL-030-retrieve_pms_sql.md), [SQL-VP-031](sql/SQL-031-retrieve_wcis_sql.md) | [PPNW_CLASS_COVERAGE_DETAIL](database-tables.md#ppnw_class_coverage_detail), [PREM_HIST_CLASS_COVERAGE](database-tables.md#prem_hist_class_coverage) | Read |

## Failure and edge-case behavior
- If no row is found for a requested policy number, `clsPolicyData` attaches an error message to the object rather than throwing.
- If a policy's `SecurePolicyCode` matches the SAIF secure code and the principal lacks the `SAIFpolicyInfo` AD resource, access is denied outright regardless of user type ([BR-VP-002](business-rules.md#br-vp-002-secure-policy-ad-resource-gate)).
- If no loss-control team assignment exists for a policy, the loss-control consultant access check denies access rather than erroring.




## Stored procedure operations

Operations extracted directly from the retrieved Oracle and SQL Server procedure and package source are summarized below.

| Operation | Description | Source | Link |
| --- | --- | --- | --- |
| Resolve current or specific policy-period employer-liability limits | Return formatted limit rows for the requested current or explicit policy period, preferring policy-period overrides and then standard defaults. | `coveragelimits_pkg` | [Details](procedures/coveragelimits_pkg.md#resolve-current-or-specific-policy-period-employer-liability-limits) |
| Resolve future employer-liability limits | Return limit rows for future-dated policy periods by evaluating adjustment windows against the future policy-period effective date. | `coveragelimits_pkg` | [Details](procedures/coveragelimits_pkg.md#resolve-future-employer-liability-limits) |
| Lookup reference employer-liability limit rows | Return individual or effective-dated standard limit rows from `EMPLOYERS_LIABILITY_LIMITS` and `EMPLOYERS_LIABILITY_FACTORS`. | `coveragelimits_pkg` | [Details](procedures/coveragelimits_pkg.md#lookup-reference-employer-liability-limit-rows) |
| Retrieve agency of record contact | Return the agency, producer, phone, address, and vendor data for the current agent of record. | `pk72846_view_policy` | [Details](procedures/pk72846_view_policy.md#retrieve-agency-of-record-contact) |
| Detect policy coverage gaps | Return gap rows sourced from adjacent policy periods and explicit `POLICY_COVERAGE_GAP` records. | `pk72846_view_policy` | [Details](procedures/pk72846_view_policy.md#detect-policy-coverage-gaps) |
| Retrieve view-policy summary detail | Return the primary view-policy summary row including entity, NAICS, premium, gap, group, reimbursement, and sales-plan data. | `pk72846_view_policy` | [Details](procedures/pk72846_view_policy.md#retrieve-view-policy-summary-detail) |
| Build ordered team-assignment rows | Return policy-team members plus synthesized office, customer-service-team, agency, and producer rows sorted by display order. | `pk72846_view_policy` | [Details](procedures/pk72846_view_policy.md#build-ordered-team-assignment-rows) |
| Retrieve policy-period history with masking rules | Return policy-period rows while applying assigned-risk masking and current-period selection rules. | `pk72846_view_policy` | [Details](procedures/pk72846_view_policy.md#retrieve-policy-period-history-with-masking-rules) |
| Resolve policy address rows | Return the preferred policy or claim address and contact row by address type or location sequence. | `pk72846_view_policy` | [Details](procedures/pk72846_view_policy.md#resolve-policy-address-rows) |
| Classify and list affiliated policies | Classify a policy affiliation family, then return member and optional totals rows for that family. | `pk72846_view_policy` | [Details](procedures/pk72846_view_policy.md#classify-and-list-affiliated-policies) |
| Resolve parent policy number | Return the parent policy number that corresponds to the resolved affiliate type. | `pk72846_view_policy` | [Details](procedures/pk72846_view_policy.md#resolve-parent-policy-number) |
| Resolve wrap-up legal name | Return the wrap-up owner legal name, escalating to the relationship policy and rate account when necessary. | `pk72846_view_policy` | [Details](procedures/pk72846_view_policy.md#resolve-wrap-up-legal-name) |
| Retrieve policy header record | Return the core policy header row together with status text and derived cancellation status. | `pk73094_policy_data` | [Details](procedures/pk73094_policy_data.md#retrieve-policy-header-record) |
| Resolve preferred account display name | Return the preferred legal name for an account number by ranking related policy rows. | `pk73094_policy_data` | [Details](procedures/pk73094_policy_data.md#resolve-preferred-account-display-name) |
| Count policy waiver rows | Return the number of `WAIVER_DETAIL` rows for the supplied policy number. | `pk82033_thirdparty` | [Details](procedures/pk82033_thirdparty.md#count-policy-waiver-rows) |
| Derive pending-cancel demand status | Check open demand rows and return `Demanded` for pending-cancel policies. | `sp72268_get_cancel_status` | [Details](procedures/sp72268_get_cancel_status.md#derive-pending-cancel-demand-status) |
| Derive cancelled-policy collection status | Evaluate collection, audit, payroll-report, and balance conditions in precedence order for cancelled policies. | `sp72268_get_cancel_status` | [Details](procedures/sp72268_get_cancel_status.md#derive-cancelled-policy-collection-status) |
| Derive application saifQuote status | Return `saifQuote` for application policies not owned by WCIS. | `sp72268_get_cancel_status` | [Details](procedures/sp72268_get_cancel_status.md#derive-application-saifquote-status) |
| Convert information-page Boolean result to a character flag | Call the wrapped Boolean function and return `Y` when true or `N` when false. | `sp72347_info_page_printed_yn` | [Details](procedures/sp72347_info_page_printed_yn.md#convert-information-page-boolean-result-to-a-character-flag) |
| Convert policy-bound Boolean result to a character flag | Call the wrapped Boolean function and return `Y` when the policy is bound or `N` when it is not. | `sp73089_get_policy_bound_flag` | [Details](procedures/sp73089_get_policy_bound_flag.md#convert-policy-bound-boolean-result-to-a-character-flag) |
| Resolve contractor email address | Look up and return the trimmed contractor email address that matches the supplied mail ID and last name. | `sp73341_external_client_lookup` | [Details](procedures/sp73341_external_client_lookup.md#resolve-contractor-email-address) |
| Resolve group-book query branch | Determine whether the supplied key should run the parent, group, or group-plus-specific-chapter query path. | `cp_claimprofile_get_group_policy_list` | [Details](procedures/cp_claimprofile_get_group_policy_list.md#resolve-group-book-query-branch) |
| Return policies valid for the requested group report date | Return distinct group-policy rows whose policy and membership windows satisfy the report-date rules. | `cp_claimprofile_get_group_policy_list` | [Details](procedures/cp_claimprofile_get_group_policy_list.md#return-policies-valid-for-the-requested-group-report-date) |
| Match loss-control consultant identity | Interpret the supplied loss-control argument as either an exact mail ID or a wildcard pattern. | `cp_claimprofile_get_sc_book` | [Details](procedures/cp_claimprofile_get_sc_book.md#match-loss-control-consultant-identity) |
| Return the active safety-consultant book | Return active, non-flat-cancel policies assigned to the matched loss-control consultant. | `cp_claimprofile_get_sc_book` | [Details](procedures/cp_claimprofile_get_sc_book.md#return-the-active-safety-consultant-book) |
| Return the latest matching external-client registrant row | Select the most recently updated active non-test `Net_Registrant` row that matches the supplied ID and last name. | `cp_external_client_lookup` | [Details](procedures/cp_external_client_lookup.md#return-the-latest-matching-external-client-registrant-row) |
| Build the open-policy agent book | Return active policy rows with certificate, rate-viewability, pending-cancel, rating, group, office, and premium fields. | `cp_get_agent_online_policy_list` | [Details](procedures/cp_get_agent_online_policy_list.md#build-the-open-policy-agent-book) |
| Append recent closed policies to the agent book | Union closed-policy rows into the result when the current-period effective date is within the last five years. | `cp_get_agent_online_policy_list` | [Details](procedures/cp_get_agent_online_policy_list.md#append-recent-closed-policies-to-the-agent-book) |
| Derive rate-viewability and pending-cancel flags | Calculate `viewableRate`, `currentCerts`, and `pendingCancel` flags for each returned policy row. | `cp_get_agent_online_policy_list` | [Details](procedures/cp_get_agent_online_policy_list.md#derive-rate-viewability-and-pending-cancel-flags) |
| Resolve the policy-in-group query branch | Determine whether the supplied key should use the parent, group-only, or group-plus-chapter membership query. | `cp_policy_in_group` | [Details](procedures/cp_policy_in_group.md#resolve-the-policy-in-group-query-branch) |
| Count matching group memberships | Return a `howMany` count for the selected branch based on the policies most recent covered period and employer-group associations. | `cp_policy_in_group` | [Details](procedures/cp_policy_in_group.md#count-matching-group-memberships) |

## Related documentation
- [Index](index.md)
- [Overview](overview.md)
- [Architecture](architecture.md)
- [Dependencies](dependencies.md)
- [Business rules](business-rules.md)
- [Database tables](database-tables.md)
- [SQL catalog](sql/index.md)
- [Security and authorization](security-authorization.md)
- [API reference](api/index.md)

> **Note:** Statements marked with `*` were inferred from code structure, naming
> conventions, or contextual evidence where direct confirmation was not available
> in source artifacts. Statements marked with `**` could not be confirmed; treat
> as unknown until verified.

## Sources
- `SAIF.Business.View.Policy\clsPolicyData.vb`
- `SAIF.Business.View.Policy\clsPolicySecurity.vb`
- `SAIF.Business.View.Policy\clsPayrollClassInfoCollection.vb`
